Conventionally, in NAND flash memory, the bit cost has been reduced by increasing the integration by downscaling the planar structure; but the downscaling of the planar structure is approaching a limit. Therefore, in recent years, technology has been proposed to stack the memory cells in the vertical direction. However, the manufacturing of such a stacked type memory device is difficult; and the reliability of the product after completion is a challenge.